<?php
/**
 * Used to validate input by user
 */
class Validation {
	
	public $errors = array();
	
	function __construct() {}
		
	/** 
	 * Validates a chip_id 
	 * @return erros[] if chip is not numeric.
	 */	
	function validateChipId($chip_id) {
		if($chip_id != '') {
			if(!is_numeric($chip_id) || $chip_id < 0){
			 	$this->errors[] = "Gadgetnummer bestaat uit cijfers";
			 }
		} else {
			$this->errors[] = "Vul een gadgetnummer in";
		}
	}

}